home *** CD-ROM | disk | FTP | other *** search
/ Supercompiler 1997 / SUPERCOMPILER97.iso / BC++ Builder / DATA.Z / ISP.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1997-02-10  |  61.1 KB  |  1,714 lines

  1. unit ISP;
  2.  
  3. interface
  4.  
  5. uses Ole2, OleCtl, Classes, Graphics, OleCtrls;
  6.  
  7. const
  8.  
  9. { NotificationModeConstants }
  10.  
  11.   icCompleteMode = 0;
  12.   icContinousMode = 1;
  13.  
  14. { StateConstants }
  15.  
  16.   prcConnecting = 1;
  17.   prcResolvingHost = 2;
  18.   prcHostResolved = 3;
  19.   prcConnected = 4;
  20.   prcDisconnecting = 5;
  21.   prcDisconnected = 6;
  22.  
  23. { TimeoutConstants }
  24.  
  25.   prcConnectTimeout = 1;
  26.   prcReceiveTimeout = 2;
  27.   prcUserTimeout = 65;
  28.  
  29. { MethodConstants }
  30.  
  31.   prcGet = 1;
  32.   prcHead = 2;
  33.   prcPost = 3;
  34.   prcPut = 4;
  35.  
  36. { FTPTypeConstants }
  37.  
  38.   ftpAscii = 0;
  39.   ftpEBCDIC = 1;
  40.   ftpImage = 2;
  41.   ftpBinary = 3;
  42.  
  43. { FTPModeConstants }
  44.  
  45.   ftpStream = 0;
  46.   ftpBlock = 1;
  47.   ftpCompressed = 2;
  48.  
  49. { FTPOperationConstants }
  50.  
  51.   ftpFile = 0;
  52.   ftpList = 1;
  53.   ftpNameList = 2;
  54.  
  55. { FTPProtocolStateConstants }
  56.  
  57.   ftpBase = 0;
  58.   ftpAuthentication = 1;
  59.   ftpTransaction = 2;
  60.  
  61. { HTTPProtocolStateConstants }
  62.  
  63.   httpBase = 0;
  64.   httpTransferring = 1;
  65.  
  66. { NNTPProtocolStateConstants }
  67.  
  68.   nntpBase = 0;
  69.   nntpTransaction = 1;
  70.   
  71. { PopProtocolStateConstants }
  72.  
  73.   popBase = 0;
  74.   popAuthorization = 1;
  75.   popTransaction = 2;
  76.   popUpdate = 3;
  77.  
  78. { SMTPProtocolStateConstants }
  79.  
  80.   smtpBase = 0;
  81.   smtpTransaction = 1;
  82.  
  83. { SCKSTATEConstants }
  84.  
  85.   sckClosed = 0;
  86.   sckOpen = 1;
  87.   sckListening = 2;
  88.   sckConnectionPending = 3;
  89.   sckResolvingHost = 4;
  90.   sckHostResolved = 5;
  91.   sckConnecting = 6;
  92.   sckConnected = 7;
  93.   sckClosing = 8;
  94.   sckError = 9;
  95.  
  96. { DocInput/Output Constants } 
  97.  
  98.   icDocNone = 0;
  99.   icDocBegin = 1;
  100.   icDocHeaders = 2;
  101.   icDocData = 3;
  102.   icDocError = 4;
  103.   icDocEnd = 5;
  104.   
  105. type
  106.  
  107.   PControlData = ^TControlData;
  108.   TControlData = record
  109.     ClassID: TCLSID;
  110.     EventIID: TIID;
  111.     EventCount: Longint;
  112.     EventDispIDs: Pointer;
  113.     LicenseKey: TBSTR;
  114.     Flags: Integer;
  115.     InstanceCount: Integer;
  116.     EnumPropDescs: TList;
  117.   end;
  118.  
  119. { TFTP }
  120.  
  121.   TFTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  122.   TFTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  123.   TFTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  124.   TFTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  125.   TFTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  126.   TFTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  127.   TFTPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  128.   TFTPListItem = procedure(Sender: TObject; const Item: Variant) of object;
  129.  
  130.   TFTP = class(TOleControl)
  131.   private
  132.     FOnError: TFTPError;
  133.     FOnTimeout: TFTPTimeout;
  134.     FOnCancel: TNotifyEvent;
  135.     FOnStateChanged: TFTPStateChanged;
  136.     FOnProtocolStateChanged: TFTPProtocolStateChanged;
  137.     FOnBusy: TFTPBusy;
  138.     FOnLog: TNotifyEvent;
  139.     FOnDocInput: TFTPDocInput;
  140.     FOnDocOutput: TFTPDocOutput;
  141.     FOnAbort: TNotifyEvent;
  142.     FOnAccount: TNotifyEvent;
  143.     FOnChangeDir: TNotifyEvent;
  144.     FOnCreateDir: TNotifyEvent;
  145.     FOnDeleteDir: TNotifyEvent;
  146.     FOnDelFile: TNotifyEvent;
  147.     FOnHelp: TNotifyEvent;
  148.     FOnmode: TNotifyEvent;
  149.     FOnNoop: TNotifyEvent;
  150.     FOnParentDir: TNotifyEvent;
  151.     FOnPrintDir: TNotifyEvent;
  152.     FOnExecute: TNotifyEvent;
  153.     FOnStatus: TNotifyEvent;
  154.     FOnReinitialize: TNotifyEvent;
  155.     FOnSystem: TNotifyEvent;
  156.     FOnSite: TNotifyEvent;
  157.     FOnType: TNotifyEvent;
  158.     FOnListItem: TFTPListItem;
  159.     function Get_Timeout(event: Smallint): Integer; stdcall;
  160.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  161.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  162.   protected
  163.     procedure InitControlData; override;
  164.   public
  165.     procedure AboutBox; stdcall;
  166.     procedure Cancel; stdcall;
  167.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  168.     procedure Authenticate(const UserId, Password: Variant); stdcall;
  169.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  170.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  171.     procedure Abort; stdcall;
  172.     procedure Account(const Account: string); stdcall;
  173.     procedure ChangeDir(const directory: string); stdcall;
  174.     procedure CreateDir(const directory: string); stdcall;
  175.     procedure DeleteDir(const directory: string); stdcall;
  176.     procedure DeleteFile(const FileName: string); stdcall;
  177.     procedure Quit; stdcall;
  178.     procedure Help(const Help: string); stdcall;
  179.     procedure Noop; stdcall;
  180.     procedure mode(ftpMode: TOleEnum); stdcall;
  181.     procedure Type_(ftpType: TOleEnum); stdcall;
  182.     procedure List(const List: string); stdcall;
  183.     procedure NameList(const NameList: string); stdcall;
  184.     procedure ParentDir; stdcall;
  185.     procedure PrintDir; stdcall;
  186.     procedure Execute(const Execute: string); stdcall;
  187.     procedure Status(const Status: string); stdcall;
  188.     procedure PutFile(const srcFileName, destFileName: string); stdcall;
  189.     procedure Reinitialize; stdcall;
  190.     procedure System; stdcall;
  191.     procedure GetFile(const srcFileName, destFileName: string); stdcall;
  192.     procedure PutFileUnique(const FileName: string); stdcall;
  193.     procedure Site(const Site: string); stdcall;
  194.     property State: Smallint index 503 read GetSmallintProp;
  195.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  196.     property ReplyString: string index 505 read GetStringProp;
  197.     property ReplyCode: Integer index 506 read GetIntegerProp;
  198.     property Errors: Variant index 508 read GetVariantProp;
  199.     property Busy: TOleBool index 509 read GetOleBoolProp;
  200.     property StateString: string index 511 read GetStringProp;
  201.     property ProtocolStateString: string index 512 read GetStringProp;
  202.     property DocInput: Variant index 1002 read GetVariantProp;
  203.     property DocOutput: Variant index 1003 read GetVariantProp;
  204.     property Operation: TOleEnum index 5 read GetOleEnumProp;
  205.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  206.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  207.   published
  208.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  209.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  210.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  211.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  212.     property UserId: string index 601 read GetStringProp write SetStringProp stored False;
  213.     property Password: string index 602 read GetStringProp write SetStringProp stored False;
  214.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  215.     property AppendToFile: TOleBool index 1 read GetOleBoolProp write SetOleBoolProp stored False;
  216.     property ListItemNotify: TOleBool index 2 read GetOleBoolProp write SetOleBoolProp stored False;
  217.     property RemoteFile: string index 3 read GetStringProp write SetStringProp stored False;
  218.     property OnError: TFTPError read FOnError write FOnError;
  219.     property OnTimeout: TFTPTimeout read FOnTimeout write FOnTimeout;
  220.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  221.     property OnStateChanged: TFTPStateChanged read FOnStateChanged write FOnStateChanged;
  222.     property OnProtocolStateChanged: TFTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  223.     property OnBusy: TFTPBusy read FOnBusy write FOnBusy;
  224.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  225.     property OnDocInput: TFTPDocInput read FOnDocInput write FOnDocInput;
  226.     property OnDocOutput: TFTPDocOutput read FOnDocOutput write FOnDocOutput;
  227.     property OnAbort: TNotifyEvent read FOnAbort write FOnAbort;
  228.     property OnAccount: TNotifyEvent read FOnAccount write FOnAccount;
  229.     property OnChangeDir: TNotifyEvent read FOnChangeDir write FOnChangeDir;
  230.     property OnCreateDir: TNotifyEvent read FOnCreateDir write FOnCreateDir;
  231.     property OnDeleteDir: TNotifyEvent read FOnDeleteDir write FOnDeleteDir;
  232.     property OnDelFile: TNotifyEvent read FOnDelFile write FOnDelFile;
  233.     property OnHelp: TNotifyEvent read FOnHelp write FOnHelp;
  234.     property Onmode: TNotifyEvent read FOnmode write FOnmode;
  235.     property OnNoop: TNotifyEvent read FOnNoop write FOnNoop;
  236.     property OnParentDir: TNotifyEvent read FOnParentDir write FOnParentDir;
  237.     property OnPrintDir: TNotifyEvent read FOnPrintDir write FOnPrintDir;
  238.     property OnExecute: TNotifyEvent read FOnExecute write FOnExecute;
  239.     property OnStatus: TNotifyEvent read FOnStatus write FOnStatus;
  240.     property OnReinitialize: TNotifyEvent read FOnReinitialize write FOnReinitialize;
  241.     property OnSystem: TNotifyEvent read FOnSystem write FOnSystem;
  242.     property OnSite: TNotifyEvent read FOnSite write FOnSite;
  243.     property OnType: TNotifyEvent read FOnType write FOnType;
  244.     property OnListItem: TFTPListItem read FOnListItem write FOnListItem;
  245.   end;
  246.  
  247. { THTML }
  248.  
  249.   THTMLError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  250.   THTMLDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  251.   THTMLDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  252.   THTMLDoRequestDoc = procedure(Sender: TObject; const URL: string; const Element, DocInput: Variant; var EnableDefault: TOleBool) of object;
  253.   THTMLDoRequestEmbedded = procedure(Sender: TObject; const URL: string; const Element, DocInput: Variant; var EnableDefault: TOleBool) of object;
  254.   THTMLDoRequestSubmit = procedure(Sender: TObject; const URL: string; const Form, DocOutput: Variant; var EnableDefault: TOleBool) of object;
  255.   THTMLDoNewElement = procedure(Sender: TObject; const ElemType: string; EndTag: TOleBool; const Attrs: Variant; const Text: string; var EnableDefault: TOleBool) of object;
  256.  
  257.   THTML = class(TOleControl)
  258.   private
  259.     FOnError: THTMLError;
  260.     FOnDocInput: THTMLDocInput;
  261.     FOnDocOutput: THTMLDocOutput;
  262.     FOnParseComplete: TNotifyEvent;
  263.     FOnLayoutComplete: TNotifyEvent;
  264.     FOnTimeout: TNotifyEvent;
  265.     FOnBeginRetrieval: TNotifyEvent;
  266.     FOnUpdateRetrieval: TNotifyEvent;
  267.     FOnEndRetrieval: TNotifyEvent;
  268.     FOnDoRequestDoc: THTMLDoRequestDoc;
  269.     FOnDoRequestEmbedded: THTMLDoRequestEmbedded;
  270.     FOnDoRequestSubmit: THTMLDoRequestSubmit;
  271.     FOnDoNewElement: THTMLDoNewElement;
  272.   protected
  273.     procedure InitControlData; override;
  274.   public
  275.     procedure AboutBox; stdcall;
  276.     procedure RequestDoc(const URL: string); stdcall;
  277.     procedure RequestAllEmbedded; stdcall;
  278.     procedure Cancel(const Message: Variant); stdcall;
  279.     property DocInput: Variant index 1002 read GetVariantProp;
  280.     property DocOutput: Variant index 1003 read GetVariantProp;
  281.     property URL: string index 1001 read GetStringProp;
  282.     property RequestURL: string index 2 read GetStringProp;
  283.     property BaseURL: string index 3 read GetStringProp;
  284.     property Forms: Variant index 4 read GetVariantProp;
  285.     property TotalWidth: Integer index 5 read GetIntegerProp;
  286.     property TotalHeight: Integer index 6 read GetIntegerProp;
  287.     property RetrieveBytesTotal: Integer index 7 read GetIntegerProp;
  288.     property RetrieveBytesDone: Integer index 8 read GetIntegerProp;
  289.     property ParseDone: TOleBool index 9 read GetOleBoolProp;
  290.     property LayoutDone: TOleBool index 10 read GetOleBoolProp;
  291.     property SourceText: string index 14 read GetStringProp;
  292.     property DocBackColor: TColor index 23 read GetColorProp;
  293.     property DocForeColor: TColor index 24 read GetColorProp;
  294.     property DocLinkColor: TColor index 25 read GetColorProp;
  295.     property DocVisitedColor: TColor index 26 read GetColorProp;
  296.     property Errors: Variant index 508 read GetVariantProp;
  297.   published
  298.     property Align;
  299.     property ParentColor;
  300.     property ParentFont;
  301.     property TabStop;
  302.     property DragCursor;
  303.     property DragMode;
  304.     property ParentShowHint;
  305.     property PopupMenu;
  306.     property ShowHint;
  307.     property TabOrder;
  308.     property Visible;
  309.     property OnDragDrop;
  310.     property OnDragOver;
  311.     property OnEndDrag;
  312.     property OnEnter;
  313.     property OnExit;
  314.     property OnStartDrag;
  315.     property OnClick;
  316.     property OnDblClick;
  317.     property OnKeyDown;
  318.     property OnKeyPress;
  319.     property OnKeyUp;
  320.     property OnMouseDown;
  321.     property OnMouseMove;
  322.     property OnMouseUp;
  323.     property DeferRetrieval: TOleBool index 11 read GetOleBoolProp write SetOleBoolProp stored False;
  324.     property ViewSource: TOleBool index 12 read GetOleBoolProp write SetOleBoolProp stored False;
  325.     property RetainSource: TOleBool index 13 read GetOleBoolProp write SetOleBoolProp stored False;
  326.     property ElemNotification: TOleBool index 15 read GetOleBoolProp write SetOleBoolProp stored False;
  327.     property Timeout: Integer index 507 read GetIntegerProp write SetIntegerProp stored False;
  328.     property Redraw: TOleBool index 17 read GetOleBoolProp write SetOleBoolProp stored False;
  329.     property UnderlineLinks: TOleBool index 18 read GetOleBoolProp write SetOleBoolProp stored False;
  330.     property UseDocColors: TOleBool index 19 read GetOleBoolProp write SetOleBoolProp stored False;
  331.     property BackImage: string index 20 read GetStringProp write SetStringProp stored False;
  332.     property BackColor: TColor index -501 read GetColorProp write SetColorProp stored False;
  333.     property ForeColor: TColor index -513 read GetColorProp write SetColorProp stored False;
  334.     property LinkColor: TColor index 21 read GetColorProp write SetColorProp stored False;
  335.     property VisitedColor: TColor index 22 read GetColorProp write SetColorProp stored False;
  336.     property Font: Variant index -512 read GetVariantProp write SetVariantProp stored False;
  337.     property FixedFont: Variant index 27 read GetVariantProp write SetVariantProp stored False;
  338.     property Heading1Font: Variant index 28 read GetVariantProp write SetVariantProp stored False;
  339.     property Heading2Font: Variant index 29 read GetVariantProp write SetVariantProp stored False;
  340.     property Heading3Font: Variant index 30 read GetVariantProp write SetVariantProp stored False;
  341.     property Heading4Font: Variant index 31 read GetVariantProp write SetVariantProp stored False;
  342.     property Heading5Font: Variant index 32 read GetVariantProp write SetVariantProp stored False;
  343.     property Heading6Font: Variant index 33 read GetVariantProp write SetVariantProp stored False;
  344.     property OnError: THTMLError read FOnError write FOnError;
  345.     property OnDocInput: THTMLDocInput read FOnDocInput write FOnDocInput;
  346.     property OnDocOutput: THTMLDocOutput read FOnDocOutput write FOnDocOutput;
  347.     property OnParseComplete: TNotifyEvent read FOnParseComplete write FOnParseComplete;
  348.     property OnLayoutComplete: TNotifyEvent read FOnLayoutComplete write FOnLayoutComplete;
  349.     property OnTimeout: TNotifyEvent read FOnTimeout write FOnTimeout;
  350.     property OnBeginRetrieval: TNotifyEvent read FOnBeginRetrieval write FOnBeginRetrieval;
  351.     property OnUpdateRetrieval: TNotifyEvent read FOnUpdateRetrieval write FOnUpdateRetrieval;
  352.     property OnEndRetrieval: TNotifyEvent read FOnEndRetrieval write FOnEndRetrieval;
  353.     property OnDoRequestDoc: THTMLDoRequestDoc read FOnDoRequestDoc write FOnDoRequestDoc;
  354.     property OnDoRequestEmbedded: THTMLDoRequestEmbedded read FOnDoRequestEmbedded write FOnDoRequestEmbedded;
  355.     property OnDoRequestSubmit: THTMLDoRequestSubmit read FOnDoRequestSubmit write FOnDoRequestSubmit;
  356.     property OnDoNewElement: THTMLDoNewElement read FOnDoNewElement write FOnDoNewElement;
  357.   end; 
  358.   
  359. { THTTP }
  360.  
  361.   THTTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  362.   THTTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  363.   THTTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  364.   THTTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  365.   THTTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  366.   THTTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  367.   THTTPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  368.  
  369.   THTTP = class(TOleControl)
  370.   private
  371.     FOnError: THTTPError;
  372.     FOnTimeout: THTTPTimeout;
  373.     FOnCancel: TNotifyEvent;
  374.     FOnStateChanged: THTTPStateChanged;
  375.     FOnProtocolStateChanged: THTTPProtocolStateChanged;
  376.     FOnBusy: THTTPBusy;
  377.     FOnLog: TNotifyEvent;
  378.     FOnDocInput: THTTPDocInput;
  379.     FOnDocOutput: THTTPDocOutput;
  380.     function Get_Timeout(event: Smallint): Integer; stdcall;
  381.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  382.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  383.   protected
  384.     procedure InitControlData; override;
  385.   public
  386.     procedure AboutBox; stdcall;
  387.     procedure Cancel; stdcall;
  388.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  389.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  390.     property State: Smallint index 503 read GetSmallintProp;
  391.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  392.     property ReplyString: string index 505 read GetStringProp;
  393.     property ReplyCode: Integer index 506 read GetIntegerProp;
  394.     property Errors: Variant index 508 read GetVariantProp;
  395.     property Busy: TOleBool index 509 read GetOleBoolProp;
  396.     property StateString: string index 511 read GetStringProp;
  397.     property ProtocolStateString: string index 512 read GetStringProp;
  398.     property DocInput: Variant index 1002 read GetVariantProp;
  399.     property DocOutput: Variant index 1003 read GetVariantProp;
  400.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  401.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  402.   published
  403.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  404.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  405.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  406.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  407.     property Document: string index 10 read GetStringProp write SetStringProp stored False;
  408.     property Method: TOleEnum index 11 read GetOleEnumProp write SetOleEnumProp stored False;
  409.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  410.     property OnError: THTTPError read FOnError write FOnError;
  411.     property OnTimeout: THTTPTimeout read FOnTimeout write FOnTimeout;
  412.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  413.     property OnStateChanged: THTTPStateChanged read FOnStateChanged write FOnStateChanged;
  414.     property OnProtocolStateChanged: THTTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  415.     property OnBusy: THTTPBusy read FOnBusy write FOnBusy;
  416.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  417.     property OnDocInput: THTTPDocInput read FOnDocInput write FOnDocInput;
  418.     property OnDocOutput: THTTPDocOutput read FOnDocOutput write FOnDocOutput;
  419.   end;
  420.  
  421. { TNNTP }
  422.   
  423.   TNNTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  424.   TNNTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  425.   TNNTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  426.   TNNTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  427.   TNNTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  428.   TNNTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  429.   TNNTPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  430.   TNNTPAuthenticateRequest = procedure(Sender: TObject; var UserId, Password: string) of object;
  431.   TNNTPAuthenticateResponse = procedure(Sender: TObject; Authenticated: TOleBool) of object;
  432.   TNNTPBanner = procedure(Sender: TObject; const Banner: string) of object;
  433.   TNNTPSelectGroup = procedure(Sender: TObject; const groupName: string; firstMessage, lastMessage, msgCount: Integer) of object;
  434.   TNNTPNextArticle = procedure(Sender: TObject; articleNumber: Integer; const messageID: string) of object;
  435.   TNNTPlastArticle = procedure(Sender: TObject; articleNumber: Integer; const messageID: string) of object;
  436.   TNNTPArticleStatus = procedure(Sender: TObject; articleNumber: Integer; const messageID: string) of object;
  437.  
  438.   TNNTP = class(TOleControl)
  439.   private
  440.     FOnError: TNNTPError;
  441.     FOnTimeout: TNNTPTimeout;
  442.     FOnCancel: TNotifyEvent;
  443.     FOnStateChanged: TNNTPStateChanged;
  444.     FOnProtocolStateChanged: TNNTPProtocolStateChanged;
  445.     FOnBusy: TNNTPBusy;
  446.     FOnLog: TNotifyEvent;
  447.     FOnDocInput: TNNTPDocInput;
  448.     FOnDocOutput: TNNTPDocOutput;
  449.     FOnAuthenticateRequest: TNNTPAuthenticateRequest;
  450.     FOnAuthenticateResponse: TNNTPAuthenticateResponse;
  451.     FOnBanner: TNNTPBanner;
  452.     FOnSelectGroup: TNNTPSelectGroup;
  453.     FOnNextArticle: TNNTPNextArticle;
  454.     FOnlastArticle: TNNTPlastArticle;
  455.     FOnArticleStatus: TNNTPArticleStatus;
  456.     function Get_Timeout(event: Smallint): Integer; stdcall;
  457.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  458.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  459.   protected
  460.     procedure InitControlData; override;
  461.   public
  462.     procedure AboutBox; stdcall;
  463.     procedure Cancel; stdcall;
  464.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  465.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  466.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  467.     procedure GetAdministrationFile(const LastUpdate: Variant); stdcall;
  468.     procedure SelectGroup(const groupName: string); stdcall;
  469.     procedure SetNextArticle; stdcall;
  470.     procedure SetLastArticle; stdcall;
  471.     procedure GetArticleNumbers(const groupName: Variant); stdcall;
  472.     procedure GetArticleHeaders(const header: string; const firstArticle, lastArticle: Variant); stdcall;
  473.     procedure GetArticleByArticleNumber(const articleNumber: Variant); stdcall;
  474.     procedure GetArticleByMessageID(const messageID: string); stdcall;
  475.     procedure GetHeaderByArticleNumber(const articleNumber: Variant); stdcall;
  476.     procedure GetHeaderByMessageID(const messageID: string); stdcall;
  477.     procedure GetBodyByArticleNumber(const articleNumber: Variant); stdcall;
  478.     procedure GetBodyByMessageID(const messageID: string); stdcall;
  479.     procedure GetStatByArticleNumber(const articleNumber: Variant); stdcall;
  480.     procedure GetOverviewFormat; stdcall;
  481.     procedure GetOverview(const firstArticle, lastArticle: Variant); stdcall;
  482.     procedure ListGroups; stdcall;
  483.     procedure ListGroupDescriptions; stdcall;
  484.     procedure ListNewGroups(const LastUpdate: Variant); stdcall;
  485.     procedure Quit; stdcall;
  486.     property State: Smallint index 503 read GetSmallintProp;
  487.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  488.     property ReplyString: string index 505 read GetStringProp;
  489.     property ReplyCode: Integer index 506 read GetIntegerProp;
  490.     property Errors: Variant index 508 read GetVariantProp;
  491.     property Busy: TOleBool index 509 read GetOleBoolProp;
  492.     property StateString: string index 511 read GetStringProp;
  493.     property ProtocolStateString: string index 512 read GetStringProp;
  494.     property DocInput: Variant index 1002 read GetVariantProp;
  495.     property DocOutput: Variant index 1003 read GetVariantProp;
  496.     property ArticleNumbersSupported: TOleBool index 1 read GetOleBoolProp;
  497.     property OverviewSupported: TOleBool index 2 read GetOleBoolProp;
  498.     property PostingAllowed: TOleBool index 3 read GetOleBoolProp;
  499.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  500.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  501.   published
  502.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  503.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  504.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  505.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  506.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  507.     property LastUpdate: TOleDate index 4 read GetOleDateProp write SetOleDateProp stored False;
  508.     property OnError: TNNTPError read FOnError write FOnError;
  509.     property OnTimeout: TNNTPTimeout read FOnTimeout write FOnTimeout;
  510.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  511.     property OnStateChanged: TNNTPStateChanged read FOnStateChanged write FOnStateChanged;
  512.     property OnProtocolStateChanged: TNNTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  513.     property OnBusy: TNNTPBusy read FOnBusy write FOnBusy;
  514.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  515.     property OnDocInput: TNNTPDocInput read FOnDocInput write FOnDocInput;
  516.     property OnDocOutput: TNNTPDocOutput read FOnDocOutput write FOnDocOutput;
  517.     property OnAuthenticateRequest: TNNTPAuthenticateRequest read FOnAuthenticateRequest write FOnAuthenticateRequest;
  518.     property OnAuthenticateResponse: TNNTPAuthenticateResponse read FOnAuthenticateResponse write FOnAuthenticateResponse;
  519.     property OnBanner: TNNTPBanner read FOnBanner write FOnBanner;
  520.     property OnSelectGroup: TNNTPSelectGroup read FOnSelectGroup write FOnSelectGroup;
  521.     property OnNextArticle: TNNTPNextArticle read FOnNextArticle write FOnNextArticle;
  522.     property OnlastArticle: TNNTPlastArticle read FOnlastArticle write FOnlastArticle;
  523.     property OnArticleStatus: TNNTPArticleStatus read FOnArticleStatus write FOnArticleStatus;
  524.   end;
  525.  
  526. { TPOP }
  527.   
  528.   TPOPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  529.   TPOPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  530.   TPOPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  531.   TPOPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  532.   TPOPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  533.   TPOPDocOutput = procedure(Sender: TObject; const DocOutput: Variant) of object;
  534.   TPOPMessageSize = procedure(Sender: TObject; msgSize: Integer) of object;
  535.   TPOPLast = procedure(Sender: TObject; Number: Integer) of object;
  536.   TPOPRefreshMessageCount = procedure(Sender: TObject; Number: Integer) of object;
  537.  
  538.   TPOP = class(TOleControl)
  539.   private
  540.     FOnError: TPOPError;
  541.     FOnTimeout: TPOPTimeout;
  542.     FOnCancel: TNotifyEvent;
  543.     FOnStateChanged: TPOPStateChanged;
  544.     FOnProtocolStateChanged: TPOPProtocolStateChanged;
  545.     FOnBusy: TPOPBusy;
  546.     FOnLog: TNotifyEvent;
  547.     FOnDocOutput: TPOPDocOutput;
  548.     FOnMessageSize: TPOPMessageSize;
  549.     FOnDelete: TNotifyEvent;
  550.     FOnReset: TNotifyEvent;
  551.     FOnLast: TPOPLast;
  552.     FOnNoop: TNotifyEvent;
  553.     FOnRefreshMessageCount: TPOPRefreshMessageCount;
  554.     function Get_Timeout(event: Smallint): Integer; stdcall;
  555.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  556.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  557.   protected
  558.     procedure InitControlData; override;
  559.   public
  560.     procedure AboutBox; stdcall;
  561.     procedure Cancel; stdcall;
  562.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  563.     procedure Authenticate(const UserId, Password: Variant); stdcall;
  564.     procedure GetDoc(const URL, Headers, OutputFile: Variant); stdcall;
  565.     procedure MessageSize(MessageNumber: Smallint); stdcall;
  566.     procedure RetrieveMessage(MessageNumber: Smallint); stdcall;
  567.     procedure Delete(MessageNumber: Smallint); stdcall;
  568.     procedure Reset; stdcall;
  569.     procedure Last; stdcall;
  570.     procedure Noop; stdcall;
  571.     procedure TopMessage(MessageNumber: Smallint); stdcall;
  572.     procedure Quit; stdcall;
  573.     procedure RefreshMessageCount; stdcall;
  574.     property State: Smallint index 503 read GetSmallintProp;
  575.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  576.     property ReplyString: string index 505 read GetStringProp;
  577.     property ReplyCode: Integer index 506 read GetIntegerProp;
  578.     property Errors: Variant index 508 read GetVariantProp;
  579.     property Busy: TOleBool index 509 read GetOleBoolProp;
  580.     property StateString: string index 511 read GetStringProp;
  581.     property ProtocolStateString: string index 512 read GetStringProp;
  582.     property DocOutput: Variant index 1003 read GetVariantProp;
  583.     property TopSupported: TOleBool index 2452 read GetOleBoolProp;
  584.     property MessageCount: Smallint index 2454 read GetSmallintProp;
  585.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  586.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  587.   published
  588.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  589.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  590.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  591.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  592.     property UserId: string index 601 read GetStringProp write SetStringProp stored False;
  593.     property Password: string index 602 read GetStringProp write SetStringProp stored False;
  594.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  595.     property TopLines: Integer index 2453 read GetIntegerProp write SetIntegerProp stored False;
  596.     property OnError: TPOPError read FOnError write FOnError;
  597.     property OnTimeout: TPOPTimeout read FOnTimeout write FOnTimeout;
  598.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  599.     property OnStateChanged: TPOPStateChanged read FOnStateChanged write FOnStateChanged;
  600.     property OnProtocolStateChanged: TPOPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  601.     property OnBusy: TPOPBusy read FOnBusy write FOnBusy;
  602.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  603.     property OnDocOutput: TPOPDocOutput read FOnDocOutput write FOnDocOutput;
  604.     property OnMessageSize: TPOPMessageSize read FOnMessageSize write FOnMessageSize;
  605.     property OnDelete: TNotifyEvent read FOnDelete write FOnDelete;
  606.     property OnReset: TNotifyEvent read FOnReset write FOnReset;
  607.     property OnLast: TPOPLast read FOnLast write FOnLast;
  608.     property OnNoop: TNotifyEvent read FOnNoop write FOnNoop;
  609.     property OnRefreshMessageCount: TPOPRefreshMessageCount read FOnRefreshMessageCount write FOnRefreshMessageCount;
  610.   end;
  611.  
  612. { TSMTP }
  613.  
  614.   TSMTPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  615.   TSMTPTimeout = procedure(Sender: TObject; event: Smallint; var Continue: TOleBool) of object;
  616.   TSMTPStateChanged = procedure(Sender: TObject; State: Smallint) of object;
  617.   TSMTPProtocolStateChanged = procedure(Sender: TObject; ProtocolState: Smallint) of object;
  618.   TSMTPBusy = procedure(Sender: TObject; isBusy: TOleBool) of object;
  619.   TSMTPDocInput = procedure(Sender: TObject; const DocInput: Variant) of object;
  620.  
  621.   TSMTP = class(TOleControl)
  622.   private
  623.     FOnError: TSMTPError;
  624.     FOnTimeout: TSMTPTimeout;
  625.     FOnCancel: TNotifyEvent;
  626.     FOnStateChanged: TSMTPStateChanged;
  627.     FOnProtocolStateChanged: TSMTPProtocolStateChanged;
  628.     FOnBusy: TSMTPBusy;
  629.     FOnLog: TNotifyEvent;
  630.     FOnDocInput: TSMTPDocInput;
  631.     FOnReset: TNotifyEvent;
  632.     FOnVerify: TNotifyEvent;
  633.     FOnExpand: TNotifyEvent;
  634.     FOnHelp: TNotifyEvent;
  635.     FOnNoop: TNotifyEvent;
  636.     function Get_Timeout(event: Smallint): Integer; stdcall;
  637.     procedure Set_Timeout(event: Smallint; Value: Integer); stdcall;
  638.     procedure Set_EnableTimer(event: Smallint; Value: TOleBool); stdcall;
  639.   protected
  640.     procedure InitControlData; override;
  641.   public
  642.     procedure AboutBox; stdcall;
  643.     procedure Cancel; stdcall;
  644.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  645.     procedure SendDoc(const URL, Headers, InputData, InputFile, OutputFile: Variant); stdcall;
  646.     procedure Reset; stdcall;
  647.     procedure Verify(const name: string); stdcall;
  648.     procedure Expand(const name: string); stdcall;
  649.     procedure Help(const helpTopic: Variant); stdcall;
  650.     procedure Noop; stdcall;
  651.     procedure Quit; stdcall;
  652.     property State: Smallint index 503 read GetSmallintProp;
  653.     property ProtocolState: Smallint index 504 read GetSmallintProp;
  654.     property ReplyString: string index 505 read GetStringProp;
  655.     property ReplyCode: Integer index 506 read GetIntegerProp;
  656.     property Errors: Variant index 508 read GetVariantProp;
  657.     property Busy: TOleBool index 509 read GetOleBoolProp;
  658.     property StateString: string index 511 read GetStringProp;
  659.     property ProtocolStateString: string index 512 read GetStringProp;
  660.     property DocInput: Variant index 1002 read GetVariantProp;
  661.     property Timeout[event: Smallint]: Integer read Get_Timeout write Set_Timeout;
  662.     property EnableTimer[event: Smallint]: TOleBool write Set_EnableTimer;
  663.   published
  664.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  665.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  666.     property NotificationMode: Smallint index 510 read GetSmallintProp write SetSmallintProp stored False;
  667.     property Logging: TOleBool index 514 read GetOleBoolProp write SetOleBoolProp stored False;
  668.     property URL: string index 1001 read GetStringProp write SetStringProp stored False;
  669.     property OnError: TSMTPError read FOnError write FOnError;
  670.     property OnTimeout: TSMTPTimeout read FOnTimeout write FOnTimeout;
  671.     property OnCancel: TNotifyEvent read FOnCancel write FOnCancel;
  672.     property OnStateChanged: TSMTPStateChanged read FOnStateChanged write FOnStateChanged;
  673.     property OnProtocolStateChanged: TSMTPProtocolStateChanged read FOnProtocolStateChanged write FOnProtocolStateChanged;
  674.     property OnBusy: TSMTPBusy read FOnBusy write FOnBusy;
  675.     property OnLog: TNotifyEvent read FOnLog write FOnLog;
  676.     property OnDocInput: TSMTPDocInput read FOnDocInput write FOnDocInput;
  677.     property OnReset: TNotifyEvent read FOnReset write FOnReset;
  678.     property OnVerify: TNotifyEvent read FOnVerify write FOnVerify;
  679.     property OnExpand: TNotifyEvent read FOnExpand write FOnExpand;
  680.     property OnHelp: TNotifyEvent read FOnHelp write FOnHelp;
  681.     property OnNoop: TNotifyEvent read FOnNoop write FOnNoop;
  682.   end;
  683.  
  684. { TTCP }
  685.  
  686.   TTCPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  687.   TTCPDataArrival = procedure(Sender: TObject; bytesTotal: Integer) of object;
  688.   TTCPConnectionRequest = procedure(Sender: TObject; requestID: Integer) of object;
  689.   TTCPSendProgress = procedure(Sender: TObject; bytesSent, bytesRemaining: Integer) of object;
  690.  
  691.   TTCP = class(TOleControl)
  692.   private
  693.     FOnError: TTCPError;
  694.     FOnDataArrival: TTCPDataArrival;
  695.     FOnConnect: TNotifyEvent;
  696.     FOnConnectionRequest: TTCPConnectionRequest;
  697.     FOnClose: TNotifyEvent;
  698.     FOnSendProgress: TTCPSendProgress;
  699.     FOnSendComplete: TNotifyEvent;
  700.   protected
  701.     procedure InitControlData; override;
  702.   public
  703.     procedure AboutBox; stdcall;
  704.     procedure Connect(const RemoteHost, RemotePort: Variant); stdcall;
  705.     procedure Listen; stdcall;
  706.     procedure Accept(requestID: Integer); stdcall;
  707.     procedure SendData(const data: Variant); stdcall;
  708.     procedure GetData(var data: Variant; const type_, maxLen: Variant); stdcall;
  709.     procedure PeekData(var data: Variant; const type_, maxLen: Variant); stdcall;
  710.     procedure Close; stdcall;
  711.     property RemoteHostIP: string index 1001 read GetStringProp;
  712.     property LocalHostName: string index 1002 read GetStringProp;
  713.     property LocalIP: string index 1003 read GetStringProp;
  714.     property SocketHandle: Integer index 1004 read GetIntegerProp;
  715.     property State: Smallint index 503 read GetSmallintProp;
  716.     property BytesReceived: Integer index 1101 read GetIntegerProp;
  717.   published
  718.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  719.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  720.     property LocalPort: Integer index 1010 read GetIntegerProp write SetIntegerProp stored False;
  721.     property OnError: TTCPError read FOnError write FOnError;
  722.     property OnDataArrival: TTCPDataArrival read FOnDataArrival write FOnDataArrival;
  723.     property OnConnect: TNotifyEvent read FOnConnect write FOnConnect;
  724.     property OnConnectionRequest: TTCPConnectionRequest read FOnConnectionRequest write FOnConnectionRequest;
  725.     property OnClose: TNotifyEvent read FOnClose write FOnClose;
  726.     property OnSendProgress: TTCPSendProgress read FOnSendProgress write FOnSendProgress;
  727.     property OnSendComplete: TNotifyEvent read FOnSendComplete write FOnSendComplete;
  728.   end;
  729.  
  730. { TUDP }
  731.   
  732.   TUDPError = procedure(Sender: TObject; Number: Smallint; var Description: string; Scode: Integer; const Source, HelpFile: string; HelpContext: Integer; var CancelDisplay: TOleBool) of object;
  733.   TUDPDataArrival = procedure(Sender: TObject; bytesTotal: Integer) of object;
  734.  
  735.   TUDP = class(TOleControl)
  736.   private
  737.     FOnError: TUDPError;
  738.     FOnDataArrival: TUDPDataArrival;
  739.   protected
  740.     procedure InitControlData; override;
  741.   public
  742.     procedure AboutBox; stdcall;
  743.     procedure SendData(const data: Variant); stdcall;
  744.     procedure GetData(var data: Variant; const type_: Variant); stdcall;
  745.     property RemoteHostIP: string index 1001 read GetStringProp;
  746.     property LocalHostName: string index 1002 read GetStringProp;
  747.     property LocalIP: string index 1003 read GetStringProp;
  748.     property SocketHandle: Integer index 1004 read GetIntegerProp;
  749.   published
  750.     property RemoteHost: string index 0 read GetStringProp write SetStringProp stored False;
  751.     property RemotePort: Integer index 502 read GetIntegerProp write SetIntegerProp stored False;
  752.     property LocalPort: Integer index 1010 read GetIntegerProp write SetIntegerProp stored False;
  753.     property OnError: TUDPError read FOnError write FOnError;
  754.     property OnDataArrival: TUDPDataArrival read FOnDataArrival write FOnDataArrival;
  755.   end;
  756.  
  757. procedure Register;  
  758.   
  759. implementation
  760.  
  761. {$J+}
  762.  
  763. { TFTP }
  764.  
  765. procedure TFTP.InitControlData;
  766. const
  767.   CEventDispIDs: array[0..26] of Integer = (
  768.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  769.     $0000022C, $000003F8, $000003F9, $0000002B, $0000002C, $0000002D,
  770.     $0000002F, $00000030, $00000031, $00000036, $00000037, $00000038,
  771.     $00000039, $0000003A, $0000003C, $0000003E, $0000003F, $00000040,
  772.     $00000042, $00000044, $00000043);
  773.   CControlData: TControlData = (
  774.     ClassID: (
  775.       D1:$B7FC354C;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  776.     EventIID: (
  777.       D1:$B7FC354B;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  778.     EventCount: 27;
  779.     EventDispIDs: @CEventDispIDs;
  780.     LicenseKey: '73f6ab30-5598-11cf-8389-0020af697014';
  781.     Flags: $00000000);
  782. begin
  783.   ControlData := @CControlData;
  784. end;
  785.  
  786. procedure TFTP.AboutBox;
  787. const
  788.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  789. begin
  790.   InvokeMethod(DispInfo, nil);
  791. end;
  792.  
  793. procedure TFTP.Cancel;
  794. const
  795.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  796. begin
  797.   InvokeMethod(DispInfo, nil);
  798. end;
  799.  
  800. procedure TFTP.Connect;
  801. const
  802.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  803. begin
  804.   InvokeMethod(DispInfo, nil);
  805. end;
  806.  
  807. procedure TFTP.Authenticate;
  808. const
  809.   DispInfo: array[0..9] of Byte = ($62,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  810. begin
  811.   InvokeMethod(DispInfo, nil);
  812. end;
  813.  
  814. procedure TFTP.SendDoc;
  815. const
  816.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  817. begin
  818.   InvokeMethod(DispInfo, nil);
  819. end;
  820.  
  821. procedure TFTP.GetDoc;
  822. const
  823.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  824. begin
  825.   InvokeMethod(DispInfo, nil);
  826. end;
  827.  
  828. procedure TFTP.Abort;
  829. const
  830.   DispInfo: array[0..7] of Byte = ($08,$00,$00,$00,$00,$01,$00,$00);
  831. begin
  832.   InvokeMethod(DispInfo, nil);
  833. end;
  834.  
  835. procedure TFTP.Account;
  836. const
  837.   DispInfo: array[0..8] of Byte = ($09,$00,$00,$00,$00,$01,$01,$00,$08);
  838. begin
  839.   InvokeMethod(DispInfo, nil);
  840. end;
  841.  
  842. procedure TFTP.ChangeDir;
  843. const
  844.   DispInfo: array[0..8] of Byte = ($0A,$00,$00,$00,$00,$01,$01,$00,$08);
  845. begin
  846.   InvokeMethod(DispInfo, nil);
  847. end;
  848.  
  849. procedure TFTP.CreateDir;
  850. const
  851.   DispInfo: array[0..8] of Byte = ($0B,$00,$00,$00,$00,$01,$01,$00,$08);
  852. begin
  853.   InvokeMethod(DispInfo, nil);
  854. end;
  855.  
  856. procedure TFTP.DeleteDir;
  857. const
  858.   DispInfo: array[0..8] of Byte = ($0C,$00,$00,$00,$00,$01,$01,$00,$08);
  859. begin
  860.   InvokeMethod(DispInfo, nil);
  861. end;
  862.  
  863. procedure TFTP.DeleteFile;
  864. const
  865.   DispInfo: array[0..8] of Byte = ($0D,$00,$00,$00,$00,$01,$01,$00,$08);
  866. begin
  867.   InvokeMethod(DispInfo, nil);
  868. end;
  869.  
  870. procedure TFTP.Quit;
  871. const
  872.   DispInfo: array[0..7] of Byte = ($0E,$00,$00,$00,$00,$01,$00,$00);
  873. begin
  874.   InvokeMethod(DispInfo, nil);
  875. end;
  876.  
  877. procedure TFTP.Help;
  878. const
  879.   DispInfo: array[0..8] of Byte = ($10,$00,$00,$00,$00,$01,$01,$00,$08);
  880. begin
  881.   InvokeMethod(DispInfo, nil);
  882. end;
  883.  
  884. procedure TFTP.Noop;
  885. const
  886.   DispInfo: array[0..7] of Byte = ($12,$00,$00,$00,$00,$01,$00,$00);
  887. begin
  888.   InvokeMethod(DispInfo, nil);
  889. end;
  890.  
  891. procedure TFTP.mode;
  892. const
  893.   DispInfo: array[0..8] of Byte = ($13,$00,$00,$00,$00,$01,$01,$00,$02);
  894. begin
  895.   InvokeMethod(DispInfo, nil);
  896. end;
  897.  
  898. procedure TFTP.Type_;
  899. const
  900.   DispInfo: array[0..8] of Byte = ($14,$00,$00,$00,$00,$01,$01,$00,$02);
  901. begin
  902.   InvokeMethod(DispInfo, nil);
  903. end;
  904.  
  905. procedure TFTP.List;
  906. const
  907.   DispInfo: array[0..8] of Byte = ($15,$00,$00,$00,$00,$01,$01,$00,$08);
  908. begin
  909.   InvokeMethod(DispInfo, nil);
  910. end;
  911.  
  912. procedure TFTP.NameList;
  913. const
  914.   DispInfo: array[0..8] of Byte = ($16,$00,$00,$00,$00,$01,$01,$00,$08);
  915. begin
  916.   InvokeMethod(DispInfo, nil);
  917. end;
  918.  
  919. procedure TFTP.ParentDir;
  920. const
  921.   DispInfo: array[0..7] of Byte = ($17,$00,$00,$00,$00,$01,$00,$00);
  922. begin
  923.   InvokeMethod(DispInfo, nil);
  924. end;
  925.  
  926. procedure TFTP.PrintDir;
  927. const
  928.   DispInfo: array[0..7] of Byte = ($18,$00,$00,$00,$00,$01,$00,$00);
  929. begin
  930.   InvokeMethod(DispInfo, nil);
  931. end;
  932.  
  933. procedure TFTP.Execute;
  934. const
  935.   DispInfo: array[0..8] of Byte = ($19,$00,$00,$00,$00,$01,$01,$00,$08);
  936. begin
  937.   InvokeMethod(DispInfo, nil);
  938. end;
  939.  
  940. procedure TFTP.Status;
  941. const
  942.   DispInfo: array[0..8] of Byte = ($1A,$00,$00,$00,$00,$01,$01,$00,$08);
  943. begin
  944.   InvokeMethod(DispInfo, nil);
  945. end;
  946.  
  947. procedure TFTP.PutFile;
  948. const
  949.   DispInfo: array[0..9] of Byte = ($1B,$00,$00,$00,$00,$01,$02,$00,$08,$08);
  950. begin
  951.   InvokeMethod(DispInfo, nil);
  952. end;
  953.  
  954. procedure TFTP.Reinitialize;
  955. const
  956.   DispInfo: array[0..7] of Byte = ($1C,$00,$00,$00,$00,$01,$00,$00);
  957. begin
  958.   InvokeMethod(DispInfo, nil);
  959. end;
  960.  
  961. procedure TFTP.System;
  962. const
  963.   DispInfo: array[0..7] of Byte = ($1D,$00,$00,$00,$00,$01,$00,$00);
  964. begin
  965.   InvokeMethod(DispInfo, nil);
  966. end;
  967.  
  968. procedure TFTP.GetFile;
  969. const
  970.   DispInfo: array[0..9] of Byte = ($1E,$00,$00,$00,$00,$01,$02,$00,$08,$08);
  971. begin
  972.   InvokeMethod(DispInfo, nil);
  973. end;
  974.  
  975. procedure TFTP.PutFileUnique;
  976. const
  977.   DispInfo: array[0..8] of Byte = ($1F,$00,$00,$00,$00,$01,$01,$00,$08);
  978. begin
  979.   InvokeMethod(DispInfo, nil);
  980. end;
  981.  
  982. procedure TFTP.Site;
  983. const
  984.   DispInfo: array[0..8] of Byte = ($20,$00,$00,$00,$00,$01,$01,$00,$08);
  985. begin
  986.   InvokeMethod(DispInfo, nil);
  987. end;
  988.  
  989. function TFTP.Get_Timeout;
  990. const
  991.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  992. begin
  993.   InvokeMethod(DispInfo, @Result);
  994. end;
  995.  
  996. procedure TFTP.Set_Timeout;
  997. const
  998.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  999. begin
  1000.   InvokeMethod(DispInfo, nil);
  1001. end;
  1002.  
  1003. procedure TFTP.Set_EnableTimer;
  1004. const
  1005.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1006. begin
  1007.   InvokeMethod(DispInfo, nil);
  1008. end;
  1009.  
  1010. { THTML }
  1011.  
  1012. procedure THTML.InitControlData;
  1013. const
  1014.   CEventDispIDs: array[0..12] of Integer = (
  1015.     $FFFFFDA0, $000003F8, $000003F9, $00000001, $00000002, $00000227,
  1016.     $00000004, $00000005, $00000006, $00000007, $00000008, $00000009,
  1017.     $0000000A);
  1018.   CControlData: TControlData = (
  1019.     ClassID: (
  1020.       D1:$B7FC355E;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1021.     EventIID: (
  1022.       D1:$B7FC355D;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1023.     EventCount: 13;
  1024.     EventDispIDs: @CEventDispIDs;
  1025.     LicenseKey: '66ab70d0-55d3-11cf-804c-00a02424e927';
  1026.     Flags: $00000007);
  1027. begin
  1028.   ControlData := @CControlData;
  1029. end;
  1030.  
  1031. procedure THTML.AboutBox;
  1032. const
  1033.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1034. begin
  1035.   InvokeMethod(DispInfo, nil);
  1036. end;
  1037.  
  1038. procedure THTML.RequestDoc;
  1039. const
  1040.   DispInfo: array[0..8] of Byte = ($22,$00,$00,$00,$00,$01,$01,$00,$08);
  1041. begin
  1042.   InvokeMethod(DispInfo, nil);
  1043. end;
  1044.  
  1045. procedure THTML.RequestAllEmbedded;
  1046. const
  1047.   DispInfo: array[0..7] of Byte = ($23,$00,$00,$00,$00,$01,$00,$00);
  1048. begin
  1049.   InvokeMethod(DispInfo, nil);
  1050. end;
  1051.  
  1052. procedure THTML.Cancel;
  1053. const
  1054.   DispInfo: array[0..8] of Byte = ($08,$02,$00,$00,$00,$01,$01,$00,$0C);
  1055. begin
  1056.   InvokeMethod(DispInfo, nil);
  1057. end;
  1058.  
  1059. { THTTP }
  1060.  
  1061. procedure THTTP.InitControlData;
  1062. const
  1063.   CEventDispIDs: array[0..8] of Integer = (
  1064.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1065.     $0000022C, $000003F8, $000003F9);
  1066.   CControlData: TControlData = (
  1067.     ClassID: (
  1068.       D1:$B7FC3563;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1069.     EventIID: (
  1070.       D1:$B7FC3562;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1071.     EventCount: 9;
  1072.     EventDispIDs: @CEventDispIDs;
  1073.     LicenseKey: '70781760-55dd-11cf-a97f-0020af3f87b5';
  1074.     Flags: $00000000);
  1075. begin
  1076.   ControlData := @CControlData;
  1077. end;
  1078.  
  1079. procedure THTTP.AboutBox;
  1080. const
  1081.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1082. begin
  1083.   InvokeMethod(DispInfo, nil);
  1084. end;
  1085.  
  1086. procedure THTTP.Cancel;
  1087. const
  1088.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1089. begin
  1090.   InvokeMethod(DispInfo, nil);
  1091. end;
  1092.  
  1093. procedure THTTP.SendDoc;
  1094. const
  1095.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  1096. begin
  1097.   InvokeMethod(DispInfo, nil);
  1098. end;
  1099.  
  1100. procedure THTTP.GetDoc;
  1101. const
  1102.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  1103. begin
  1104.   InvokeMethod(DispInfo, nil);
  1105. end;
  1106.  
  1107. function THTTP.Get_Timeout;
  1108. const
  1109.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1110. begin
  1111.   InvokeMethod(DispInfo, @Result);
  1112. end;
  1113.  
  1114. procedure THTTP.Set_Timeout;
  1115. const
  1116.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1117. begin
  1118.   InvokeMethod(DispInfo, nil);
  1119. end;
  1120.  
  1121. procedure THTTP.Set_EnableTimer;
  1122. const
  1123.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1124. begin
  1125.   InvokeMethod(DispInfo, nil);
  1126. end;
  1127.  
  1128. { TNNTP }
  1129.  
  1130. procedure TNNTP.InitControlData;
  1131. const
  1132.   CEventDispIDs: array[0..15] of Integer = (
  1133.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1134.     $0000022C, $000003F8, $000003F9, $00000000, $00000001, $00000002,
  1135.     $00000003, $00000004, $00000005, $00000006);
  1136.   CControlData: TControlData = (
  1137.     ClassID: (
  1138.       D1:$B7FC3568;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1139.     EventIID: (
  1140.       D1:$B7FC3567;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1141.     EventCount: 16;
  1142.     EventDispIDs: @CEventDispIDs;
  1143.     LicenseKey: '86c3e880-5595-11cf-96e7-0080c7c3c284';
  1144.     Flags: $00000000);
  1145. begin
  1146.   ControlData := @CControlData;
  1147. end;
  1148.  
  1149. procedure TNNTP.AboutBox;
  1150. const
  1151.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1152. begin
  1153.   InvokeMethod(DispInfo, nil);
  1154. end;
  1155.  
  1156. procedure TNNTP.Cancel;
  1157. const
  1158.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1159. begin
  1160.   InvokeMethod(DispInfo, nil);
  1161. end;
  1162.  
  1163. procedure TNNTP.Connect;
  1164. const
  1165.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1166. begin
  1167.   InvokeMethod(DispInfo, nil);
  1168. end;
  1169.  
  1170. procedure TNNTP.SendDoc;
  1171. const
  1172.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  1173. begin
  1174.   InvokeMethod(DispInfo, nil);
  1175. end;
  1176.  
  1177. procedure TNNTP.GetDoc;
  1178. const
  1179.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  1180. begin
  1181.   InvokeMethod(DispInfo, nil);
  1182. end;
  1183.  
  1184. procedure TNNTP.GetAdministrationFile;
  1185. const
  1186.   DispInfo: array[0..8] of Byte = ($05,$00,$00,$00,$00,$01,$01,$00,$0C);
  1187. begin
  1188.   InvokeMethod(DispInfo, nil);
  1189. end;
  1190.  
  1191. procedure TNNTP.SelectGroup;
  1192. const
  1193.   DispInfo: array[0..8] of Byte = ($06,$00,$00,$00,$00,$01,$01,$00,$08);
  1194. begin
  1195.   InvokeMethod(DispInfo, nil);
  1196. end;
  1197.  
  1198. procedure TNNTP.SetNextArticle;
  1199. const
  1200.   DispInfo: array[0..7] of Byte = ($07,$00,$00,$00,$00,$01,$00,$00);
  1201. begin
  1202.   InvokeMethod(DispInfo, nil);
  1203. end;
  1204.  
  1205. procedure TNNTP.SetLastArticle;
  1206. const
  1207.   DispInfo: array[0..7] of Byte = ($08,$00,$00,$00,$00,$01,$00,$00);
  1208. begin
  1209.   InvokeMethod(DispInfo, nil);
  1210. end;
  1211.  
  1212. procedure TNNTP.GetArticleNumbers;
  1213. const
  1214.   DispInfo: array[0..8] of Byte = ($09,$00,$00,$00,$00,$01,$01,$00,$0C);
  1215. begin
  1216.   InvokeMethod(DispInfo, nil);
  1217. end;
  1218.  
  1219. procedure TNNTP.GetArticleHeaders;
  1220. const
  1221.   DispInfo: array[0..10] of Byte = ($0A,$00,$00,$00,$00,$01,$03,$00,$08,$0C,$0C);
  1222. begin
  1223.   InvokeMethod(DispInfo, nil);
  1224. end;
  1225.  
  1226. procedure TNNTP.GetArticleByArticleNumber;
  1227. const
  1228.   DispInfo: array[0..8] of Byte = ($0B,$00,$00,$00,$00,$01,$01,$00,$0C);
  1229. begin
  1230.   InvokeMethod(DispInfo, nil);
  1231. end;
  1232.  
  1233. procedure TNNTP.GetArticleByMessageID;
  1234. const
  1235.   DispInfo: array[0..8] of Byte = ($0C,$00,$00,$00,$00,$01,$01,$00,$08);
  1236. begin
  1237.   InvokeMethod(DispInfo, nil);
  1238. end;
  1239.  
  1240. procedure TNNTP.GetHeaderByArticleNumber;
  1241. const
  1242.   DispInfo: array[0..8] of Byte = ($0D,$00,$00,$00,$00,$01,$01,$00,$0C);
  1243. begin
  1244.   InvokeMethod(DispInfo, nil);
  1245. end;
  1246.  
  1247. procedure TNNTP.GetHeaderByMessageID;
  1248. const
  1249.   DispInfo: array[0..8] of Byte = ($0E,$00,$00,$00,$00,$01,$01,$00,$08);
  1250. begin
  1251.   InvokeMethod(DispInfo, nil);
  1252. end;
  1253.  
  1254. procedure TNNTP.GetBodyByArticleNumber;
  1255. const
  1256.   DispInfo: array[0..8] of Byte = ($0F,$00,$00,$00,$00,$01,$01,$00,$0C);
  1257. begin
  1258.   InvokeMethod(DispInfo, nil);
  1259. end;
  1260.  
  1261. procedure TNNTP.GetBodyByMessageID;
  1262. const
  1263.   DispInfo: array[0..8] of Byte = ($10,$00,$00,$00,$00,$01,$01,$00,$08);
  1264. begin
  1265.   InvokeMethod(DispInfo, nil);
  1266. end;
  1267.  
  1268. procedure TNNTP.GetStatByArticleNumber;
  1269. const
  1270.   DispInfo: array[0..8] of Byte = ($11,$00,$00,$00,$00,$01,$01,$00,$0C);
  1271. begin
  1272.   InvokeMethod(DispInfo, nil);
  1273. end;
  1274.  
  1275. procedure TNNTP.GetOverviewFormat;
  1276. const
  1277.   DispInfo: array[0..7] of Byte = ($12,$00,$00,$00,$00,$01,$00,$00);
  1278. begin
  1279.   InvokeMethod(DispInfo, nil);
  1280. end;
  1281.  
  1282. procedure TNNTP.GetOverview;
  1283. const
  1284.   DispInfo: array[0..9] of Byte = ($13,$00,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1285. begin
  1286.   InvokeMethod(DispInfo, nil);
  1287. end;
  1288.  
  1289. procedure TNNTP.ListGroups;
  1290. const
  1291.   DispInfo: array[0..7] of Byte = ($14,$00,$00,$00,$00,$01,$00,$00);
  1292. begin
  1293.   InvokeMethod(DispInfo, nil);
  1294. end;
  1295.  
  1296. procedure TNNTP.ListGroupDescriptions;
  1297. const
  1298.   DispInfo: array[0..7] of Byte = ($15,$00,$00,$00,$00,$01,$00,$00);
  1299. begin
  1300.   InvokeMethod(DispInfo, nil);
  1301. end;
  1302.  
  1303. procedure TNNTP.ListNewGroups;
  1304. const
  1305.   DispInfo: array[0..8] of Byte = ($16,$00,$00,$00,$00,$01,$01,$00,$0C);
  1306. begin
  1307.   InvokeMethod(DispInfo, nil);
  1308. end;
  1309.  
  1310. procedure TNNTP.Quit;
  1311. const
  1312.   DispInfo: array[0..7] of Byte = ($18,$00,$00,$00,$00,$01,$00,$00);
  1313. begin
  1314.   InvokeMethod(DispInfo, nil);
  1315. end;
  1316.  
  1317. function TNNTP.Get_Timeout;
  1318. const
  1319.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1320. begin
  1321.   InvokeMethod(DispInfo, @Result);
  1322. end;
  1323.  
  1324. procedure TNNTP.Set_Timeout;
  1325. const
  1326.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1327. begin
  1328.   InvokeMethod(DispInfo, nil);
  1329. end;
  1330.  
  1331. procedure TNNTP.Set_EnableTimer;
  1332. const
  1333.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1334. begin
  1335.   InvokeMethod(DispInfo, nil);
  1336. end;
  1337.  
  1338. { TPOP }
  1339.  
  1340. procedure TPOP.InitControlData;
  1341. const
  1342.   CEventDispIDs: array[0..13] of Integer = (
  1343.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1344.     $0000022C, $000003F9, $000009A1, $000009A2, $000009A3, $000009A4,
  1345.     $000009A6, $000009A7);
  1346.   CControlData: TControlData = (
  1347.     ClassID: (
  1348.       D1:$B7FC356E;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1349.     EventIID: (
  1350.       D1:$B7FC356D;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1351.     EventCount: 14;
  1352.     EventDispIDs: @CEventDispIDs;
  1353.     LicenseKey: 'fb7663e0-5505-11cf-a676-0020af6a0bf2';
  1354.     Flags: $00000000);
  1355. begin
  1356.   ControlData := @CControlData;
  1357. end;
  1358.  
  1359. procedure TPOP.AboutBox;
  1360. const
  1361.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1362. begin
  1363.   InvokeMethod(DispInfo, nil);
  1364. end;
  1365.  
  1366. procedure TPOP.Cancel;
  1367. const
  1368.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1369. begin
  1370.   InvokeMethod(DispInfo, nil);
  1371. end;
  1372.  
  1373. procedure TPOP.Connect;
  1374. const
  1375.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1376. begin
  1377.   InvokeMethod(DispInfo, nil);
  1378. end;
  1379.  
  1380. procedure TPOP.Authenticate;
  1381. const
  1382.   DispInfo: array[0..9] of Byte = ($62,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1383. begin
  1384.   InvokeMethod(DispInfo, nil);
  1385. end;
  1386.  
  1387. procedure TPOP.GetDoc;
  1388. const
  1389.   DispInfo: array[0..10] of Byte = ($EC,$03,$00,$00,$00,$01,$03,$00,$0C,$0C,$0C);
  1390. begin
  1391.   InvokeMethod(DispInfo, nil);
  1392. end;
  1393.  
  1394. procedure TPOP.MessageSize;
  1395. const
  1396.   DispInfo: array[0..8] of Byte = ($98,$09,$00,$00,$00,$01,$01,$00,$02);
  1397. begin
  1398.   InvokeMethod(DispInfo, nil);
  1399. end;
  1400.  
  1401. procedure TPOP.RetrieveMessage;
  1402. const
  1403.   DispInfo: array[0..8] of Byte = ($99,$09,$00,$00,$00,$01,$01,$00,$02);
  1404. begin
  1405.   InvokeMethod(DispInfo, nil);
  1406. end;
  1407.  
  1408. procedure TPOP.Delete;
  1409. const
  1410.   DispInfo: array[0..8] of Byte = ($9A,$09,$00,$00,$00,$01,$01,$00,$02);
  1411. begin
  1412.   InvokeMethod(DispInfo, nil);
  1413. end;
  1414.  
  1415. procedure TPOP.Reset;
  1416. const
  1417.   DispInfo: array[0..7] of Byte = ($9B,$09,$00,$00,$00,$01,$00,$00);
  1418. begin
  1419.   InvokeMethod(DispInfo, nil);
  1420. end;
  1421.  
  1422. procedure TPOP.Last;
  1423. const
  1424.   DispInfo: array[0..7] of Byte = ($9C,$09,$00,$00,$00,$01,$00,$00);
  1425. begin
  1426.   InvokeMethod(DispInfo, nil);
  1427. end;
  1428.  
  1429. procedure TPOP.Noop;
  1430. const
  1431.   DispInfo: array[0..7] of Byte = ($97,$09,$00,$00,$00,$01,$00,$00);
  1432. begin
  1433.   InvokeMethod(DispInfo, nil);
  1434. end;
  1435.  
  1436. procedure TPOP.TopMessage;
  1437. const
  1438.   DispInfo: array[0..8] of Byte = ($9D,$09,$00,$00,$00,$01,$01,$00,$02);
  1439. begin
  1440.   InvokeMethod(DispInfo, nil);
  1441. end;
  1442.  
  1443. procedure TPOP.Quit;
  1444. const
  1445.   DispInfo: array[0..7] of Byte = ($9E,$09,$00,$00,$00,$01,$00,$00);
  1446. begin
  1447.   InvokeMethod(DispInfo, nil);
  1448. end;
  1449.  
  1450. procedure TPOP.RefreshMessageCount;
  1451. const
  1452.   DispInfo: array[0..7] of Byte = ($C4,$09,$00,$00,$00,$01,$00,$00);
  1453. begin
  1454.   InvokeMethod(DispInfo, nil);
  1455. end;
  1456.  
  1457. function TPOP.Get_Timeout;
  1458. const
  1459.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1460. begin
  1461.   InvokeMethod(DispInfo, @Result);
  1462. end;
  1463.  
  1464. procedure TPOP.Set_Timeout;
  1465. const
  1466.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1467. begin
  1468.   InvokeMethod(DispInfo, nil);
  1469. end;
  1470.  
  1471. procedure TPOP.Set_EnableTimer;
  1472. const
  1473.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1474. begin
  1475.   InvokeMethod(DispInfo, nil);
  1476. end;
  1477.  
  1478. { TSMTP }
  1479.  
  1480. procedure TSMTP.InitControlData;
  1481. const
  1482.   CEventDispIDs: array[0..12] of Integer = (
  1483.     $FFFFFDA0, $00000227, $00000228, $00000229, $0000022A, $0000022B,
  1484.     $0000022C, $000003F8, $0000012C, $0000012D, $0000012E, $0000012F,
  1485.     $00000130);
  1486.   CControlData: TControlData = (
  1487.     ClassID: (
  1488.       D1:$B7FC3573;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1489.     EventIID: (
  1490.       D1:$B7FC3572;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1491.     EventCount: 13;
  1492.     EventDispIDs: @CEventDispIDs;
  1493.     LicenseKey: 'b7444ee0-55be-11cf-96e7-0080c7c3c284';
  1494.     Flags: $00000000);
  1495. begin
  1496.   ControlData := @CControlData;
  1497. end;
  1498.  
  1499. procedure TSMTP.AboutBox;
  1500. const
  1501.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1502. begin
  1503.   InvokeMethod(DispInfo, nil);
  1504. end;
  1505.  
  1506. procedure TSMTP.Cancel;
  1507. const
  1508.   DispInfo: array[0..7] of Byte = ($08,$02,$00,$00,$00,$01,$00,$00);
  1509. begin
  1510.   InvokeMethod(DispInfo, nil);
  1511. end;
  1512.  
  1513. procedure TSMTP.Connect;
  1514. const
  1515.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1516. begin
  1517.   InvokeMethod(DispInfo, nil);
  1518. end;
  1519.  
  1520. procedure TSMTP.SendDoc;
  1521. const
  1522.   DispInfo: array[0..12] of Byte = ($ED,$03,$00,$00,$00,$01,$05,$00,$0C,$0C,$0C,$0C,$0C);
  1523. begin
  1524.   InvokeMethod(DispInfo, nil);
  1525. end;
  1526.  
  1527. procedure TSMTP.Reset;
  1528. const
  1529.   DispInfo: array[0..7] of Byte = ($C8,$00,$00,$00,$00,$01,$00,$00);
  1530. begin
  1531.   InvokeMethod(DispInfo, nil);
  1532. end;
  1533.  
  1534. procedure TSMTP.Verify;
  1535. const
  1536.   DispInfo: array[0..8] of Byte = ($C9,$00,$00,$00,$00,$01,$01,$00,$08);
  1537. begin
  1538.   InvokeMethod(DispInfo, nil);
  1539. end;
  1540.  
  1541. procedure TSMTP.Expand;
  1542. const
  1543.   DispInfo: array[0..8] of Byte = ($CA,$00,$00,$00,$00,$01,$01,$00,$08);
  1544. begin
  1545.   InvokeMethod(DispInfo, nil);
  1546. end;
  1547.  
  1548. procedure TSMTP.Help;
  1549. const
  1550.   DispInfo: array[0..8] of Byte = ($CB,$00,$00,$00,$00,$01,$01,$00,$0C);
  1551. begin
  1552.   InvokeMethod(DispInfo, nil);
  1553. end;
  1554.  
  1555. procedure TSMTP.Noop;
  1556. const
  1557.   DispInfo: array[0..7] of Byte = ($CC,$00,$00,$00,$00,$01,$00,$00);
  1558. begin
  1559.   InvokeMethod(DispInfo, nil);
  1560. end;
  1561.  
  1562. procedure TSMTP.Quit;
  1563. const
  1564.   DispInfo: array[0..7] of Byte = ($CD,$00,$00,$00,$00,$01,$00,$00);
  1565. begin
  1566.   InvokeMethod(DispInfo, nil);
  1567. end;
  1568.  
  1569. function TSMTP.Get_Timeout;
  1570. const
  1571.   DispInfo: array[0..8] of Byte = ($FB,$01,$00,$00,$03,$02,$01,$00,$02);
  1572. begin
  1573.   InvokeMethod(DispInfo, @Result);
  1574. end;
  1575.  
  1576. procedure TSMTP.Set_Timeout;
  1577. const
  1578.   DispInfo: array[0..9] of Byte = ($FB,$01,$00,$00,$00,$04,$02,$00,$02,$03);
  1579. begin
  1580.   InvokeMethod(DispInfo, nil);
  1581. end;
  1582.  
  1583. procedure TSMTP.Set_EnableTimer;
  1584. const
  1585.   DispInfo: array[0..9] of Byte = ($01,$02,$00,$00,$00,$04,$02,$00,$02,$0B);
  1586. begin
  1587.   InvokeMethod(DispInfo, nil);
  1588. end;
  1589.  
  1590. { TTCP }
  1591.  
  1592. procedure TTCP.InitControlData;
  1593. const
  1594.   CEventDispIDs: array[0..6] of Integer = (
  1595.     $FFFFFDA0, $0000041B, $0000047F, $00000480, $00000483, $00000481,
  1596.     $00000482);
  1597.   CControlData: TControlData = (
  1598.     ClassID: (
  1599.       D1:$B7FC3584;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1600.     EventIID: (
  1601.       D1:$B7FC3583;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1602.     EventCount: 7;
  1603.     EventDispIDs: @CEventDispIDs;
  1604.     LicenseKey: 'b315c530-5298-11cf-aaa2-0020af2cee5e';
  1605.     Flags: $00000000);
  1606. begin
  1607.   ControlData := @CControlData;
  1608. end;
  1609.  
  1610. procedure TTCP.AboutBox;
  1611. const
  1612.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1613. begin
  1614.   InvokeMethod(DispInfo, nil);
  1615. end;
  1616.  
  1617. procedure TTCP.Connect;
  1618. const
  1619.   DispInfo: array[0..9] of Byte = ($09,$02,$00,$00,$00,$01,$02,$00,$0C,$0C);
  1620. begin
  1621.   InvokeMethod(DispInfo, nil);
  1622. end;
  1623.  
  1624. procedure TTCP.Listen;
  1625. const
  1626.   DispInfo: array[0..7] of Byte = ($4E,$04,$00,$00,$00,$01,$00,$00);
  1627. begin
  1628.   InvokeMethod(DispInfo, nil);
  1629. end;
  1630.  
  1631. procedure TTCP.Accept;
  1632. const
  1633.   DispInfo: array[0..8] of Byte = ($4F,$04,$00,$00,$00,$01,$01,$00,$03);
  1634. begin
  1635.   InvokeMethod(DispInfo, nil);
  1636. end;
  1637.  
  1638. procedure TTCP.SendData;
  1639. const
  1640.   DispInfo: array[0..8] of Byte = ($F4,$03,$00,$00,$00,$01,$01,$00,$0C);
  1641. begin
  1642.   InvokeMethod(DispInfo, nil);
  1643. end;
  1644.  
  1645. procedure TTCP.GetData;
  1646. const
  1647.   DispInfo: array[0..10] of Byte = ($F3,$03,$00,$00,$00,$01,$03,$00,$8C,$0C,$0C);
  1648. begin
  1649.   InvokeMethod(DispInfo, nil);
  1650. end;
  1651.  
  1652. procedure TTCP.PeekData;
  1653. const
  1654.   DispInfo: array[0..10] of Byte = ($50,$04,$00,$00,$00,$01,$03,$00,$8C,$0C,$0C);
  1655. begin
  1656.   InvokeMethod(DispInfo, nil);
  1657. end;
  1658.  
  1659. procedure TTCP.Close;
  1660. const
  1661.   DispInfo: array[0..7] of Byte = ($51,$04,$00,$00,$00,$01,$00,$00);
  1662. begin
  1663.   InvokeMethod(DispInfo, nil);
  1664. end;
  1665.  
  1666. { TUDP }
  1667.  
  1668. procedure TUDP.InitControlData;
  1669. const
  1670.   CEventDispIDs: array[0..1] of Integer = (
  1671.     $FFFFFDA0, $0000041B);
  1672.   CControlData: TControlData = (
  1673.     ClassID: (
  1674.       D1:$B7FC3587;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1675.     EventIID: (
  1676.       D1:$B7FC3586;D2:$8CE7;D3:$11CF;D4:($97,$54,$00,$AA,$00,$C0,$09,$08));
  1677.     EventCount: 2;
  1678.     EventDispIDs: @CEventDispIDs;
  1679.     LicenseKey: 'b315c530-5298-11cf-aaa2-0020af2cee5e';
  1680.     Flags: $00000000);
  1681. begin
  1682.   ControlData := @CControlData;
  1683. end;
  1684.  
  1685. procedure TUDP.AboutBox;
  1686. const
  1687.   DispInfo: array[0..7] of Byte = ($D8,$FD,$FF,$FF,$00,$01,$00,$00);
  1688. begin
  1689.   InvokeMethod(DispInfo, nil);
  1690. end;
  1691.  
  1692. procedure TUDP.SendData;
  1693. const
  1694.   DispInfo: array[0..8] of Byte = ($F4,$03,$00,$00,$00,$01,$01,$00,$0C);
  1695. begin
  1696.   InvokeMethod(DispInfo, nil);
  1697. end;
  1698.  
  1699. procedure TUDP.GetData;
  1700. const
  1701.   DispInfo: array[0..9] of Byte = ($F3,$03,$00,$00,$00,$01,$02,$00,$8C,$0C);
  1702. begin
  1703.   InvokeMethod(DispInfo, nil);
  1704. end;
  1705.  
  1706. procedure Register;
  1707. begin
  1708.   RegisterComponents('Internet', [TFTP, THTML, THTTP, TNNTP, TPOP, TSMTP, TTCP, TUDP]);
  1709. end;
  1710.  
  1711.  
  1712. end.
  1713.  
  1714.